home *** CD-ROM | disk | FTP | other *** search
/ Borland JBuilder 6 / jbuilder6.iso / Documents / FAQ JavaScript / jscript.txt < prev   
Encoding:
Internet Message Format  |  2001-02-03  |  34.5 KB

  1. From: "CoModerator of RU.JAVASCRIPT" <koronin@yahoo.com>
  2. Date: Tue, 6 Feb 2001 09:21:37 +0000 (UTC)
  3. Subj: RU.JAVASCRIPT FAQ
  4.  
  5. I. Docs and Links
  6. 1.∩ε°δΦ≥σ ∞σφ  ≥≤Σα, πΣσ σ±≥ⁿ ΩαΩΦσ ΩφΦµΩΦ
  7. (∞εµφε Φ φα αφπδΦΘ±Ωε∞) ∩ε ²⌡ε≥απ≤, δ≤≈°σ Γ ²δσΩ≥≡εφφε∞ ΓΦΣσ
  8.  
  9. >╩φΦπΦ ∩ε JavaScript:
  10. >>From: "Vitaly Vasilchuk" <vitaly@basis.ru.kiev.ua>
  11.  
  12. www.izone.com.ua/info/download_web.html
  13.  
  14. >>From : shilk@telecom.chita.ru
  15.  
  16. ┬ε≥ ≈≥ε   φα≡√δ Γ ±Γεσ Γ≡σ∞ :
  17.  
  18. 1) Hα≥αδΦ  ┴σδⁿ≥ΦΩεΓα, ╚≡Φφα ╩≤τΦφα. ╠σ≥εΣ√ Φ ⌠≤φΩ÷ΦΦ JavaScript.
  19. http://webims.virtualave.net/docs/js/jsrus/index.htm
  20.  
  21. 2) Hσßεδⁿ°εΘ ±∩≡αΓε≈φΦΩ ∩ε JavaScript by Ataev RUSlan
  22. http://gid.spb.ru/RUS/Java.htm
  23.  
  24. 3) JavaScript ╪απ τα °απε∞ by └φΣ≡σΘ ╩≤τΦφ
  25. http://www.mjk.msk.ru/~dron/html/js.shtml
  26.  
  27. >>From : Artem Babadzhanyants
  28.  
  29. http://developer.netscape.com
  30. http://www.javascript.com
  31. http://www.javascript.ru
  32. http://www.citycat.ru/doc/
  33. http://godegisel.protey.ru/library/docs/www/
  34.  
  35. >>From: Alexey Medvedev 2:463/733.137
  36.  
  37. www.bratta.com/dhtml/ - ∩≡ΦΩεδⁿφ√Θ JS ≥Φ∩α Flash/vector graphics
  38. ∞φεπε ∩≡Φ∞σ≡εΓ Σδ  ΓφσΣ≡σφΦ  Γ ±ΓεΦ ±≥≡αφΦ≈ΩΦ.
  39.  
  40. www.dansteinman.com/dynduo/  - Ω≡ε±± ß≡ε≤τσ≡ DHTML API φΦτΩεπε
  41. ≡εΓφ  (IE4,5 , NN4 , Mozilla5). ╨ατ≡αßα≥√Γασ≥±  ∩εΣ GNU license.
  42. ±≥ⁿ ≡σαδΦτα÷Φ  widget-εΓ (Ωφε∩ΩΦ, check, list, menu, window, scroll .etc.)
  43.  
  44. www.htmlguru.com - "≡εΣεφα≈αδⁿφΦΩ" DHTML :)
  45. ±≥Φδⁿφε ε⌠ε≡∞δσφ√Θ ±αΘ≥ ± ≤≈σßφΦΩα∞Φ ∩ε DHTML
  46.  
  47. deep.kiev.ua - ∩≡Φ∞σ≡ ≡σαδΦτα÷ΦΦ π≡α⌠εΓ Σδ  NN-DHTML
  48. (∞α±°≥αßΦ≡εΓαφΦσ ∩εΣ εΩφε, εß≡αßε≥Ωα resize event ßστ reload - NN).
  49.  
  50. deep.kiev.ua/~netlib/ - ßΦßδΦε≥σΩα ∩ε webdesign. ╬±φεΓφα  ≈α±≥ⁿ
  51. ε±Γ ∙σφα JS , DHTML ± ∩≡Φ∞σ≡α∞Φ (φα∩≡Φ∞σ≡ ΩαΩ _±ετΣαΓα≥ⁿ_ GIF Φ PNG
  52. α≡≥ΦφΩΦ φα JS Γ NN ΦδΦ ΩαΩ ±Σσδα≥ⁿ σ⌠⌠σΩ≥ hover Γ NN ).
  53.  
  54.  
  55. >>From: Evgenij Koronin <koronin@yahoo.com>
  56.  
  57. W3 concorcium resources
  58. http://www.w3.org/MarkUp/W3 - HyperText Markup Language
  59. http://www.w3.org/MarkUp/W3 - XHTML Recommendation
  60. http://www.w3.org/CSS/W3 - CSS and Style
  61. http://www.w3.org/DOM/W3 - Document Object Model
  62. http://www.w3.org/XML/W3 - XML
  63. http://www.w3.org/TV/W3 - TV and the Web
  64.  
  65. HTML, CSS and Javascript
  66. http://www.blooberry.com/indexdot/html/ - HTML Reference
  67. http://www.blooberry.com/indexdot/css/ - CSS Reference
  68. http://www.htmlib.com/where.htm - HTMLib 4.0 - complete HTML/CSS/Javascript
  69. reference (download)
  70.  
  71. Complete Libraries
  72. http://msdn.microsoft.com/workshop/ - MSDN Workshop
  73. http://developer.netscape.com/docs/index.html - Netscape DevEdge
  74. Documentation Library
  75. http://www.wdvl.com - Web Developer's Virtual Library
  76.  
  77.  
  78. Articles and Tutorials
  79. http://builder.cnet.com - CNET Web Builder
  80. http://www.siteexperts.com - Site Experts
  81. http://www.webdeveloper.com - Web Developer
  82. http://www.zdnet.com/devhead/ - ZDNet Developer Head
  83. http://hotwired.lycos.com/webmonkey/ - Hotwired Webmonkey
  84. http://developer.earthweb.com/ - Earthweb Developer
  85. http://www.webreview.com/ - Web Review
  86. http://www.webreference.com/ - Web Reference
  87. http://www.1001tutorials.com/ - 1001 Tutorials
  88.  
  89.  
  90. Γ±≥αΓδ Θ≥σ ±ΓεΦ ±±√δΩΦ!
  91.  
  92.  
  93. II. General javascript
  94.  
  95. 1. ≥αΩ, ≈≥εß√ φα ±εß√≥Φσ onclick - ⌠εφ ∞σφ δ± ?
  96.  
  97. >> From : Vitaly Karmazinsky                  2:5020/400      Mon 13 Dec 99
  98. 12:24
  99.  
  100. Q> ≥αΩ, ≈≥εß√ φα ±εß√≥Φσ onclick - ⌠εφ ∞σφ δ± ?
  101.  
  102. <A HREF="http://www.yahoo.com"
  103. onMouseOver="document.bgColor='red'">Yahoo</a>
  104.  
  105. ┴≤Σ≤∙ΦΘ ⌠εφ ε∩≡σΣσδ σ≥±  ∞σµΣ≤ ΩαΓ√≈Ωα∞Φ  ' '
  106.  
  107. red -  Ω≡α±φ√Θ;
  108. black - ≈σ≡φ√Θ;
  109. yellow - µσδ≥√Θ;
  110. white -  ßσδ√Θ;
  111. green - τσδσφ√Θ;
  112. brown - Ωε≡Φ≈φσΓ√Θ;
  113.  
  114. bgColor - ⌠εφ;
  115. fgColor - ≥σΩ±≥;
  116. linkColor - ÷Γσ≥ ±±√δΩΦ;
  117.  
  118.  
  119. >>From Evgenij Koronin <koronin@yahoo.com>
  120. <a href="javascript:document.bgColor='red'">change color</a>
  121.  
  122.  
  123. 2. ┬εß∙σ∞, φαΣε σ±δΦ ΓΩδ■≈σφ js ∩εΩατα≥ⁿ εΣΦφ Ω≤±ε≈σΩ html ΩεΣα, α σ±δΦ
  124. Γ√Ωδ■≈σφ Σ≡≤πεΘ.
  125.  
  126. From: "Michael A. Kangin" <mak@complife.net>
  127.  
  128. <script>
  129. document.writeln('╬ΣΦφ Ω≤±ε≈σΩ')
  130. </script>
  131. <noscript>
  132. ─≡≤πεΘ Ω≤±ε≈σΩ
  133. </noscript>
  134.  
  135. 3. └ ΩαΩ φα JavaScript ∩ε πΦ∩σpcc√δΩσ ∞εµφε ∩σpσΣα≥ⁿ
  136.    ∩αpα∞σ≥p (φα∩pΦ∞σp φατΓαφΦσ ⌠αΘδα) cε εΣφεΘ c≥pαφΦ≈ΩΦ
  137.    φα Σp≤π≤■? ╚Σσ  cεc≥εΦ≥ Γ ≥ε∞, ≈≥εß√ c≥pαφΦ≈Ωα pαßε≥αδα
  138.    ∩ε-pατφε∞≤ Γ ταΓΦcΦ∞εc≥Φ ε≥ ≥επε, ε≥Ω≤Σα φα φσ╕ Γε°δΦ.
  139.  
  140.    >> From : Michael A. Kangin                   2:5020/400      Fri 28 Jan
  141. 00 03:26
  142.  
  143. 1. ╬≥Ω≤Σα ∩≡Φ°δΦ φα Σαφφ≤■ ±≥≡αφΦ≈Ω≤, ∞εµφε ∩ε∩≡εßεΓα≥ⁿ ≤τφα≥ⁿ ∩ε
  144. document.referrer
  145.  
  146. 2. ╧α≡α∞σ≥≡√ ∞εµφε ∩σ≡σΣαΓα≥ⁿ ΩαΩ <a href="file.htm?parameter=value">, Φ
  147. Γ√≥α±ΩΦΓα≥ⁿ Φ⌡ ΩαΩ parameter=document.location.search;
  148.  
  149.  
  150. 4.  ╧ε∞φ■, ≈≥ε Σδ  ≥επε, ≈≥εß√ ∩σpσΣα≥ⁿ ∩αpα∞σ≥p, φαΣε:
  151. <A HREF="webpage.htm?param1=value1¶m2=value2&...">ssd</A>
  152. └ Γε≥ ΩαΩ Σεß√≥ⁿ τφα≈σφΦ  ∩αpα∞σ≥pεΓ, φσ ∩ε∞φ■.
  153.  
  154. >>From: Evgenij Koronin <koronin@yahoo.com>
  155. Modified code taken from MSTV OneWorld UI
  156. ----------------------------------------------
  157. var QueryString = new Array();
  158. QueryString["_"]="";
  159.  
  160. function unspace( qs_element ) {
  161.  return qs_element.split( '+' ).join( ' ' );
  162. }
  163.  
  164. if ( location.search.length > 1 ) {
  165.  var qs_query = location.search.substring( 1, location.search.length );
  166.  var qs_pairs = qs_query.split( '&' );
  167.  
  168.  for ( var qs_index = 0; qs_index < qs_pairs.length; qs_index++ ) {
  169.   var qs_element = qs_pairs[qs_index].split( '=' );
  170.   QueryString[qs_element[0]] = unspace( unescape( qs_element[1] ) );
  171.  }
  172. }
  173. ----------------------------------------------
  174. Φ±∩εδⁿτεΓα≥ⁿ:  var myVar = QueryString["parameter"];
  175.  
  176. 5. ∩oΣcΩaµΦ≥e plz ΩaΩ cΣeδa≥ⁿ Γ html cc√δΩy Ωo≥opa  ß√ paßo≥aδa ΩaΩ Ω≥o∩Ωa
  177. back Γ ßpoyτepe
  178.  
  179. >> From : Igor Kanshin                        2:463/1124.50   Sat 05 Feb 00
  180. 11:39
  181.  
  182. <a href="JavaScript:history.back()">Back</a>
  183.  
  184. 6. ╧pσΣ∩εδεµΦ∞ φαΣε ±ετΣα≥ⁿ φεΓεσ εΩε°Ωε, φε φσ φα ε±φεΓσ yµσ ±y∙σ±≥Γy■∙σπε
  185. html-⌠αΘδα, α ±⌠εp∞ΦpεΓα≥ⁿ σπε φα JavaScript Φ ∩ε≥ε∞ yµσ ε≥Ωp√≥ⁿ Γ φεΓε∞
  186. εΩφσ.
  187. >> From : Andrew Konovalov                    2:5030/1139     Sun 13 Feb 00
  188. 09:11
  189.     newWindow = window.open(...);
  190.     newWindow.document.write(...);
  191.  
  192. >>From: Evgenij Koronin <koronin@yahoo.com>
  193.  newWindow = window.open("");
  194.  s=your_html;
  195.  with (newWindow.document)
  196.  {
  197.   open();
  198.   write(s);
  199.   close();
  200.  }
  201.  
  202.  
  203.  
  204. 7. └ ΩαΩ ∞εµφε ταπ≡≤τΦ≥ⁿ Ωα≡≥ΦφΩ≤ Σε ≥επε,
  205. ΩαΩ φα≈φ╕≥ ταπ≡≤µα≥ⁿ±  ε±≥αδⁿφα  ≈α±≥ⁿ ±≥≡αφΦ÷√?
  206.  
  207. >> From : V.Kobychev                          2:5020/400      Mon 21 Feb 00
  208. 15:44
  209. <html><head>
  210. <script LANGUAGE="JavaScript">
  211. <!--
  212. function PreloadImages()
  213. {
  214.  if (document.images)
  215.  {
  216.   var imgFiles = PreloadImages.arguments;
  217.   var preloadArray = new Array();
  218.   for (var i=0; i<imgFiles.length; i++)
  219.   {
  220.    preloadArray[i] = new Image;
  221.    preloadArray[i].src = imgFiles[i];
  222.   }
  223.   }
  224. }
  225. PreloadImages('picture1.jpg','picture2.jpg','picture3.gif'); // Φ σ∙σ
  226. ±ΩεδⁿΩε ≤πεΣφε Ωα≡≥ΦφεΩ
  227.  // -->
  228. </script>
  229. <body>
  230. ....
  231. </body>
  232. </html>
  233.  
  234. 8. ╩αΩ ²≥εΘ ⌡pσφⁿ■ ∩εδⁿτεΓα≥ⁿ±  ????? Hα∩Φ±αφφε window.opener.δ -δ  ;((
  235.  
  236. >> From : Vitaly Karmazinsky                  2:5020/400      Fri 17 Mar 00
  237. 13:45
  238. window.opener.document.my_form.my_element.value = 'test';
  239.  
  240. ┬ε≥ ≥αΩΦ∞ ΩεΣε∞ ∞εµφε Γ±≥αΓΦ≥ⁿ Σαφφ√σ Γ ⌠ε≡∞≤
  241. ≡εΣΦ≥σδⁿ±Ωεπε εΩφα. ╨αßε≥ασ≥ ΓστΣσ.
  242.  
  243. 9."Nikolai Levtchenko" <Nikolai.Levtchenko@p73.f4001.n5020.z2.fidonet.org>
  244. wrote in message >
  245. > ╤≤∙σ±≥Γ≤σ≥ δΦ ±αßµ? ╫≥εß√ ∞εµφε ß√δε ∩ε°απεΓε Γ√∩εδφ ≥ⁿ, ∩≡εΓσ≡ ≥ⁿ
  246. ±ε±ε≥ε φΦσ
  247. > ∩σ≡σ∞σφφ√⌡ Φ ≥.Σ.?
  248. >
  249.  
  250. http://msdn.microsoft.com/scripting/debugger/default.htm
  251. ╬≈σφⁿ ≤Σα≈φ√Θ ε≥δαΣ≈ΦΩ ε≥ Netscape
  252. ftp://ftp.netscape.com/pub/jsdebug/rtm/jsd10su.jar
  253.  
  254.  
  255. III. Browser, mouse buttons, cookies, new windows etc.
  256.  
  257. 1.≤ Ωεπε-φΦß≤Σⁿ σ±≥ⁿ ≤φΦΓσ≡±αδⁿφ√Θ ΩεΣ ≡αßε≥√ ± subj (⌠≤φΩ÷ΦΦ ≥Φ∩α
  258. setcookie,
  259. getcookie, killcookie..... )
  260.  
  261. >>From: Evgenij Koronin <koronin@yahoo.com>
  262. //---------------------------------------------------------------------
  263. // Function to return the value of the cookie specified by "name".
  264.  
  265. // Parameter:
  266. //     name     String object containing the cookie name.
  267.  
  268. // Return:      String object containing the cookie value, or null if
  269. //              the cookie does not exist.
  270. //---------------------------------------------------------------------
  271. function GetCookie (name)
  272. {
  273.     var arg  = name + "=";
  274.     var alen = arg.length;
  275.     var clen = document.cookie.length;
  276.     var i    = 0;
  277.  
  278.     while (i < clen)
  279.     {
  280.         var j = i + alen;
  281.         if (document.cookie.substring(i, j) == arg)
  282.           return getCookieVal (j);
  283.         i = document.cookie.indexOf(" ", i) + 1;
  284.         if (i == 0) break;
  285.     }
  286.     return null;
  287. }
  288. //---------------------------------------------------------------------
  289. // Function to get a cookie.
  290. //---------------------------------------------------------------------
  291. function getCookieVal( offset )
  292. {
  293.     var endstr = document.cookie.indexOf (";", offset);
  294.  
  295.     if (endstr == -1)
  296.         endstr = document.cookie.length;
  297.     return unescape(document.cookie.substring(offset, endstr));
  298. }
  299. //---------------------------------------------------------------------
  300. // Function to set a cookie.
  301. //---------------------------------------------------------------------
  302. function SetCookie( name, value )
  303. {
  304.     var argv    = SetCookie.arguments;
  305.     var argc    = SetCookie.arguments.length;
  306.     var expires = (argc > 2) ? argv[2] : null;
  307.     var path    = (argc > 3) ? argv[3] : null;
  308.     var domain  = (argc > 4) ? argv[4] : null;
  309.     var secure  = (argc > 5) ? argv[5] : false;
  310.  
  311.     document.cookie =
  312.         name + "=" + escape (value) +
  313.         ((expires == null) ? "" : ("; expires=" + expires.toGMTString())) +
  314.         ((path == null) ? "" : ("; path=" + path)) +
  315.         ((domain == null) ? "" : ("; domain=" + domain)) +
  316.         ((secure == true) ? "; secure" : "");
  317. }
  318. //---------------------------------------------------------------------
  319. // Function to delete a cookie. (Sets expiration date)
  320. //    name - String object containing the cookie name
  321. //---------------------------------------------------------------------
  322. function DeleteCookie (name)
  323. {
  324.     var exp  = new Date();
  325.     var cval = GetCookie (name);
  326.  
  327.     exp.setTime (exp.getTime() - 1);  // This cookie is history
  328.     document.cookie = name + "=" + cval + "; expires=" + exp.toGMTString();
  329. }
  330.  
  331. >> From : Vitaly Vasilchuk                    2:5020/400      Wed 12 Apr 00
  332. 15:03
  333.  
  334. <script language="JavaScript">
  335. <!--
  336. // ≡ατεß≡α≥ⁿ τφα≈σφΦσ Ωδ■≈α
  337. function extractCookieValue(val)
  338.  
  339.   if ((endOfCookie = document.cookie.indexOf(";", val)) == -1)
  340.  
  341.     endOfCookie = document.cookie.length;
  342.   }
  343.   return unescape(document.cookie.substring(val, endOfCookie)) ;
  344. }
  345.  
  346. // ≈≥σφΦσ Ωδ■≈α
  347. function ReadCookie(cookiename) {
  348.   var numOfCookies = document.cookie.length;
  349.   var nameOfCookie = cookiename + "=";
  350.   var cookieLen = nameOfCookie.length;
  351.   var x = 0 ;
  352.   while (x <= numOfCookies) {
  353.     var y = (x + cookieLen);
  354.     if (document.cookie.substring(x, y) == nameOfCookie)
  355.       return (extractCookieValue(y));
  356.       x = document.cookie.indexOf(" ", x) + 1;
  357.     if (x == 0)
  358.       break;
  359.   }
  360.   return "";
  361. }
  362.  
  363. // ±ετΣαφΦσ Ωδ■≈α
  364. // Σδ  ≤ΣαδσφΦ  - expiredays = -1
  365. function createCookie(name, value, expiredays)
  366.  
  367. var todayDate = new Date();
  368. todayDate.setDate(todayDate.getDate() + expiredays);
  369. document.cookie = name +
  370.                   "=" +
  371.                   value +
  372.                   "; expires=" +
  373.     todayDate.toGMTString() +
  374.     ";"
  375. }
  376.  
  377. // ∩≡Φ∞σ≡ ταπ≡≤τΩΦ
  378. function LoadCookies() {
  379.   document.forms[0].UserName.value=ReadCookie("UserName");
  380. }
  381.  
  382. // ∩≡Φ∞σ≡ ±ε⌡≡αφσφΦ 
  383. function SaveCookies() {
  384.   createCookie("UserName", document.forms[0].UserName.value, 30);
  385. }
  386.  
  387. //-->
  388. </script>
  389.  
  390. 2. ∩≡Φ∞σ≡ ±Ω≡Φ∩≥α τα∩≡σ∙σφΦ  ≡αßε≥√ ∩≡αΓεΘ Ωφε∩ΩΦ ∞√°Φ.
  391.  
  392. >> From : Oleg Arkhipov                       2:5020/400      Mon 06 Dec 99
  393. 11:01
  394. >>From: "Oleg Arkhipov" <arol@hippo.ru>
  395.  
  396.  Hα°σδ Γ FAQ-Server ( http://zl0ba.i.am ) ∩≡Φ∞σ≡ ±Ω≡Φ∩≥α τα∩≡σ∙σφΦ  ≡αßε≥√
  397. ∩≡αΓεΘ Ωφε∩ΩΦ ∞√°Φ.
  398.  
  399. <html>
  400. <head>
  401.  
  402. <script LANGUAGE="JavaScript1.1">
  403. <!-- Begin
  404.  function right(e) {
  405.   if (navigator.appName == 'Netscape' &&
  406.                              (e.which == 3 || e.which == 2)) {
  407.    alert("Sorry, you do not have permission to right click.");
  408.    return false;
  409.   } else if (navigator.appName == 'Microsoft Internet Explorer' &&
  410.                           (event.button == 2 || event.button == 3)) {
  411.    alert("Sorry, you do not have permission to right click.");
  412.    return false;
  413.   }
  414.   return true;
  415. }
  416.  
  417. document.onmousedown=right;
  418. if (document.layers) window.captureEvents(Event.MOUSEDOWN);
  419. window.onmousedown=right;
  420. //  End -->
  421. </script>
  422. </head>
  423. <body>
  424.  
  425. </body>
  426. </html>
  427.  
  428.  
  429. 3. ╒ε≥σδε±ⁿ ß√ τφα≥ⁿ ΩαΩ ε∩≡σΣσδΦ≥ⁿ Φ ∞εµφε δΦ Γεεß∙σ ε∩≡σΣσδΦ≥ⁿ, ΩαΩα 
  430. Ωφε∩Ωα φαµα≥α ≤ ∞√°Φ.
  431.  
  432. >> From : Evgenij Koronin
  433.  
  434. Φ±∩εδⁿτ≤Θ εß·σΩ≥ event
  435. The Event Object is supported by both Internet Explorer 4.0 and Netscape
  436. (from 3.0). Properties of the event object are available for every event
  437. that occurs on every scriptable object within a document.
  438.  
  439. event.button
  440. The button property contains an integer value which represents which of the
  441. mouse buttons were used when the event occurred. The possible values are:
  442.  
  443. Value Button pressed
  444. 0 No mouse button pressed
  445. 1 Left mouse button pressed
  446. 2 Right mouse button pressed
  447. 4 Middle button pressed
  448.  
  449. 4.  ╤ ²≥Φ∞ Γε∩≡ε±ε∞   τα°σδ φσ±ΩεδⁿΩε Φτ ΣαδσΩα. ╩εφΩ≡σ≥φε, ΩδΦσφ≥≤
  450. φσεß⌡εΣΦ∞
  451. Φφ≥σ≡⌠σΘ ≥Φ∩α WinApp, ≥ε σ±≥ⁿ popupMenu ∩ε ∩≡αΓεΘ Ωφε∩Ωσ ∞√°Φ. Hα
  452. WebClub.ru   φα°σδ Ωεσ-≈≥ε, φε ≥α∞ ∩≡Φ∞σ≡ φα VBScript Φ ≈σ≡στ ±Ω≡Φ∩δσ≥.
  453. ╒ε≥σδε±ⁿ ß√ ΩαΩ-φΦß≤Σⁿ ∩ε ∩≡ε∙σ, ∩ε ∩≡εδσ≥α≡±Φ, Φ φα JavaScript.
  454.  
  455. >> From : Evgenij Koronin
  456. ╧≡ε±≥σΘ°ΦΘ ∩≡Φ∞σ≡:
  457.  
  458. <script>
  459. <!--
  460. function click() {
  461. if (event.button==2) {
  462. alert(Hello')
  463. }
  464. document.onmousedown=click
  465. ///-->
  466.  
  467.  
  468. ≥σ∩σ≡ⁿ ±∞ε≥≡Φ,Γ∞σ±≥ε αδσ≡≥α ∞εµφε Γ√τ√Γα≥ⁿ ⌠≤φΩ÷Φ■, ∩ε Ωεε≡εΘ ß≤Σσ≥
  469. ∩εΩατ√Γα≥ⁿ±  ±δεΘ ± δΦφΩα∞Φ (π≡α⌠ΦΩα ΦδΦ σ∙σ ≈≥ε - Γ φσ∞ σ∙σ ∞εµφε ∩εΣ±Γσ≥Ω≤
  470. ±Σσδα≥ⁿ - ²≥ε ≤µσ ε≥Σσδⁿφ√Θ Γε∩≡ε±). ┬ ±δεσ Ωε≡ε≈σ Φ ß≤Σσ≥ ∞σφ■, πδαΓφεσ
  471. ∩εΦ∞σ≥ⁿ Ωεε≡ΣΦφα≥√ ∞√°Φ ≈σ≡στ ≥ε≥ µσ εß·σΩ≥ event Φ ±δεΘ ε≥∩ετΦ÷ΦεφΦ≡εΓα≥ⁿ
  472. φα ²≥Φ Ωεε≡ΣΦφα≥√. - Γ±σ. ─α - ∩εΣ HH φαΣε ß≤Σσ≥ Φ±∩εδⁿτεΓα≥ⁿ
  473. document.captureEvent(MOUSEDOWN) - ∩ε±∞ε≥≡Φ HH ΣεΩ≤, α ≥ε ╚┼ ∩εφΦ∞ασ≥, ≈≥ε ≤
  474. ΣεΩ≤∞σφ≥α σ±≥ⁿ onmousedown, α HH  ßστ ²≥επε  - φσ≥.
  475. ╚ ∩ε≈Φ≥αΘ ΓφΦ∞α≥σδⁿφε ∩≡ε event handlers. - Γ Ωεφ÷σ ⌠≤φΩ÷ΦΦ, ∩ε ∞εσ∞≤ φαΣε
  476. ΓετΓ≡α≥Φ≥ⁿ false - ≥επΣα ±α∞ε ∞σφ■ ε≡ΦπΦφαδⁿφεσ φσ ß≤Σσ≥ Γ√ΣαΓα≥ⁿ± .
  477.  
  478. ─α ±εΓ±σ∞ ταß√δ - ≡ατδΦ≈Φ  ╚┼ Φ HH
  479. for IE
  480. event.button
  481. event.x
  482. event.y
  483.  
  484. for NN
  485. event.which
  486. event.pageX
  487. event.pageY
  488.  
  489. 5.═σ ∞επ ß√ ≥√ ∩≡ΦΓσ±≥Φ ∩≡Φ∞σ≡ ±Ω≡Φ∩≥ΦΩα, Ωε≥ε≡√Θ ß√ ≥σΩ±≥ε∞ ∩Φ±αδ online
  490. ΦδΦ offline?
  491.  
  492. >> From : Evgenij Koronin                     2:5020/400      Mon 27 Mar 00
  493. 19:52
  494.  
  495. ╩αΩ ΣΓα ∩αδⁿ÷α - Γε≥, ≤ ∞σφ  ∩Φ°σ≥
  496.  
  497. <html>
  498. <head><title> Online test </title>
  499. </head>
  500.  
  501. <body>
  502. Internet Explorer in <B>
  503. <script language="javascript1.2">
  504. <!--
  505. if (document.all)
  506.  document.write(navigator.onLine?"online":"offline");
  507. // -->
  508. </script>
  509. </B> mode
  510. </body>
  511. </html>
  512.  
  513. 6. ╨α±∩σ≈α≥Ωα ±≥≡αφΦ÷√ Φτ ΩεΣα
  514. >>From: Nikolay Pichtin
  515.  
  516. ▌≥ε ∩ε∩≡εß≤Θ≥σ.
  517.  
  518.  <SCRIPT>
  519.  function displayPrintButton() {
  520.    if ((navigator.appName.indexOf("Netscape") > -1 &&
  521.       parseInt(navigator.appVersion) >= 4) ||
  522.       (navigator.appName.indexOf("Microsoft") > -1 &&
  523.        parseInt(navigator.appVersion) >= 4) ) {
  524.        document.write
  525.         ("<FORM><INPUT TYPE=button VALUE='Print'
  526.         ("<FORM>onClick='printCurrentPage();'></FORM>");
  527.         }
  528.     }
  529.  
  530.  function printCurrentPage() {
  531.     if (navigator.appName.indexOf("Microsoft") > -1 &&
  532.         navigator.appVersion.indexOf("5.") == -1) {
  533.        // IE4
  534.        OLECMDID_PRINT = 6;
  535.        OLECMDEXECOPT_DONTPROMPTUSER = 2;
  536.        OLECMDEXECOPT_PROMPTUSER = 1;
  537.        WebBrowser =
  538.         '<OBJECT ID="WebBrowser1" WIDTH=0 HEIGHT=0
  539. CLASSID="CLSID:8856F961-340A-11D0-A96B-00C04FD705A2"></OBJECT>';
  540.        document.body.insertAdjacentHTML('beforeEnd', WebBrowser);
  541.        WebBrowser1.ExecWB(OLECMDID_PRINT,   OLECMDEXECOPT_PROMPTUSER);
  542.        WebBrowser1.outerHTML = "";
  543.       }
  544.     else {
  545.       // N4 IE5
  546.       window.print();
  547.       }
  548.     }
  549.  
  550.     displayPrintButton();
  551.     </SCRIPT>
  552.  
  553.  
  554. 7.  ╩αΩ ε∩≡σΣσδΦ≥ⁿ - ΩαΩε■ ≤ ■τσ≡α ß≡α≤τσ≡?
  555.  
  556. >> From : Artem Babadzhanyants
  557.  
  558. >╩αΩ ε∩≡σΣσδΦ≥ⁿ - ΩαΩε■ ≤ ■τσ≡α ß≡α≤τσ≡?
  559.  
  560. // Browser propeties check library. Version 1.02
  561. // (C) Zalog 2000.  Permission granted to reuse and distribute.
  562. // e-mail: zalog@pyramid-studio.com
  563.  
  564. function Browser(){
  565.   this.checkScreen=Browser_checkScreen;
  566.   this.getCookieVal=Browser_getCookieVal;
  567.   this.fixCookieDate=Browser_fixCookieDate;
  568.   this.getCookie=Browser_getCookie;
  569.   this.setCookie=Browser_setCookie;
  570.   this.deleteCookie=Browser_deleteCookie;
  571.   this.getHostName=Browser_getHostName;
  572.   this.getHostAddress=Browser_getHostAddress;
  573.   this.agent=navigator.userAgent.toLowerCase();
  574.   (navigator.appName)?this.name=navigator.appName:this.name=null;
  575.  
  576. (navigator.appCodeName)?this.codeName=navigator.appCodeName:this.codeName=nu
  577. ll;
  578.  
  579. (navigator.securityPolicy)?this.securityPolicy=navigator.securityPolicy:this
  580. ..securityPolicy=null;
  581.   this.versionHi=parseInt(navigator.appVersion);
  582.   this.version=parseFloat(navigator.appVersion);
  583.   if(navigator.cpuClass){
  584.     this.cpu=navigator.cpuClass.toLowerCase();
  585.     this.cpuClass="Unknown CPU class, including Sun SPARC";
  586.     if(navigator.cpuClass.indexOf("x86")!= -1) this.cpuClass="Intel
  587. processor";
  588.  
  589.  
  590.  
  591.  
  592. if((navigator.cpuClass.indexOf("68k")!= -1)||(navigator.cpuClass.indexOf("pp
  593. c")!= -1)) this.cpuClass="Motorola processor";
  594.     if(navigator.cpuClass.indexOf("alpha")!= -1) this.cpuClass="Digital
  595. processor";
  596.   }else{
  597.     this.cpu=null;
  598.     this.cpuClass=null;
  599.   }
  600.   (navigator.onLine )?this.onLine=navigator.onLine:this.onLine=null;
  601.   if(navigator.cookieEnabled)this.cookieEnabled=navigator.cookieEnabled;
  602.   else{
  603.     var expdate=new Date();
  604.     expdate.setTime(expdate.getTime()+(365*24*60*60*1000));
  605.     this.fixCookieDate(expdate);
  606.     this.setCookie("test_js","safe to delete",expdate,"/");
  607.  
  608. (this.getCookie("test_js"))?this.cookieEnabled=true:this.cookieEnabled=false
  609. ;
  610.     this.deleteCookie("test_js","/");
  611.   }
  612.   if(navigator.language)this.language=navigator.language;
  613.   else if(navigator.browserLanguage)this.language=navigator.browserLanguage;
  614.     else this.language=null;
  615.  
  616. (navigator.systemLanguage)?this.systemLanguage=navigator.systemLanguage:this
  617. ..systemLanguage=null;
  618.  
  619. (navigator.userLanguage)?this.userLanguage=navigator.userLanguage:this.userL
  620. anguage=null;
  621.  
  622. this.Netscape=((this.agent.indexOf('mozilla')!=-1)&&(this.agent.indexOf('spo
  623. ofer')==-1)&&(this.agent.indexOf('compatible')==-1)&&(this.agent.indexOf('op
  624. era')==-1)&&(this.agent.indexOf('webtv')==-1));
  625.    this.Netscape2=(this.Netscape&&(this.versionHi==2));
  626.    this.Netscape3=(this.Netscape&&(this.versionHi==3));
  627.    this.Netscape4=(this.Netscape&&(this.versionHi==4));
  628.    this.Netscape4up=(this.Netscape&&(this.versionHi>=4));
  629.    this.Netscape5=(this.Netscape&&(this.versionHi==5));
  630.    this.Netscape5up=(this.Netscape&&(this.versionHi>=5));
  631.  
  632. this.NavigatorOnly=(this.Netscape&&((this.agent.indexOf(";nav")!=-1)||(this.
  633. agent.indexOf("; nav")!=-1)));
  634.   this.IE=(this.agent.indexOf("msie") != -1);
  635.    this.IE3=(this.IE&&(this.versionHi<4));
  636.    this.IE4=(this.IE&&(this.versionHi==4)&&(this.agent.indexOf("msie
  637. 5.0")==-1));
  638.    this.IE4up=(this.IE&&(this.versionHi>=4));
  639.    this.IE5=(this.IE&&(this.versionHi==4)&&(this.agent.indexOf("msie
  640. 5.0")!=-1));
  641.    this.IE5up=(this.IE&&!this.IE3&&!this.IE4);
  642.    if(this.IE5){
  643.      this.versionHi=parseInt(this.agent.substr(this.agent.indexOf("5.")));
  644.      this.version=parseFloat(this.agent.substr(this.agent.indexOf("5.")));
  645.    }
  646.   this.AOL=(this.agent.indexOf("aol")!= -1);
  647.    this.AOL3=(this.AOL&&this.IE3);
  648.    this.AOL4=(this.AOL&&this.IE4);
  649.   this.Opera=(this.agent.indexOf("opera")!=-1);
  650.   this.WebTV=(this.agent.indexOf("webtv")!=-1);
  651.   if(this.Netscape2||this.IE3)this.jsVersion=1.0;
  652.   else if(this.Netscape3||this.Opera)this.jsVersion=1.1;
  653.   else
  654. if((this.Netscape4&&(this.version<=4.05))||this.IE4)this.jsVersion=1.2;
  655.   else
  656. if((this.Netscape4&&(this.version>4.05))||this.IE5)this.jsVersion=1.3;
  657.   else if(this.Netscape5)this.jsVersion=1.4;
  658.   else if(this.Netscape&&(this.versionHi>5))this.jsVersion=1.4;
  659.   else if(this.IE&&(this.versionHi>5))this.jsVersion=1.3;
  660.   else if(_jsVersion>1.3)this.jsVersion=_jsVersion;
  661.   else this.jsVersion=0.0;
  662.   this.vbVersion=vbVer;
  663.  
  664. this.osWin=((this.agent.indexOf("win")!=-1)||(this.agent.indexOf("16bit")!=-
  665. 1));
  666.  
  667. this.osWin95=((this.agent.indexOf("win95")!=-1)||(this.agent.indexOf("window
  668. s 95")!=-1));
  669.  
  670. this.osWinCE=((this.agent.indexOf("wince")!=-1)||(this.agent.indexOf("window
  671. s ce")!=-1)||(this.agent.indexOf("win ce")!=-1));
  672.  
  673. this.osWin16=((this.agent.indexOf("win16")!=-1)||(this.agent.indexOf("16bit"
  674. )!=-1)||(this.agent.indexOf("windows
  675. 3.1")!=-1)||(this.agent.indexOf("windows 16-bit")!=-1));
  676.   this.osWin31=((this.agent.indexOf("windows
  677. 3.1")!=-1)||(this.agent.indexOf("win16")!=-1)||(this.agent.indexOf("windows
  678. 16-bit")!=-1));
  679.  
  680. this.osWin98=((this.agent.indexOf("win98")!=-1)||(this.agent.indexOf("window
  681. s 98")!=-1));
  682.  
  683. this.osWinNT=((this.agent.indexOf("winnt")!=-1)||(this.agent.indexOf("window
  684. s nt")!=-1));
  685.   this.osWin2000=(this.osWinNT||(this.agent.indexOf("nt 5.0")!=-1));
  686.  
  687. this.osWin32=(this.osWin95||this.osWinNT||this.osWin98||this.osWin2000||((th
  688. is.versionHi>=4)&&(navigator.platform=="Win32"))||(this.agent.indexOf("win32
  689. ")!=-1)||(this.agent.indexOf("32bit")!=-1));
  690.  
  691. this.osOS2=((this.agent.indexOf("os/2")!=-1)||(navigator.appVersion.indexOf(
  692. "OS/2")!=-1)||(this.agent.indexOf("ibm-webexplorer")!=-1));
  693.   this.osMac=(this.agent.indexOf("mac")!=-1);
  694.  
  695. this.osMac68k=(this.osMac&&((this.agent.indexOf("68k")!=-1)||(this.agent.ind
  696. exOf("68000")!=-1)));
  697.   this.osMacPPC=(this.osMac &&
  698. ((this.agent.indexOf("ppc")!=-1)||(this.agent.indexOf("powerpc")!=-1)));
  699.   this.osSun=(this.agent.indexOf("sunos")!=-1);
  700.   this.osSun4=(this.agent.indexOf("sunos 4")!=-1);
  701.   this.osSun5=(this.agent.indexOf("sunos 5")!=-1);
  702.   this.osSuni86=(this.osSun&&(this.agent.indexOf("i86")!=-1));
  703.   this.osIrix=(this.agent.indexOf("irix")!=-1);
  704.   this.osIrix5=(this.agent.indexOf("irix 5")!=-1);
  705.   this.osIrix6=((this.agent.indexOf("irix
  706. 6")!=-1)||(this.agent.indexOf("irix6")!=-1));
  707.   this.osHPUx=(this.agent.indexOf("hp-ux")!=-1);
  708.   this.osHPUx9=(this.osHPUx&&(this.agent.indexOf("09.")!=-1));
  709.   this.osHPUx10=(this.osHPUx&&(this.agent.indexOf("10.")!=-1));
  710.   this.osAIX=(this.agent.indexOf("aix")!=-1);
  711.   this.osAIX1=(this.agent.indexOf("aix 1")!=-1);
  712.   this.osAIX2=(this.agent.indexOf("aix 2")!=-1);
  713.   this.osAIX3=(this.agent.indexOf("aix 3")!=-1);
  714.   this.osAIX4=(this.agent.indexOf("aix 4")!=-1);
  715.   this.osLinux=(this.agent.indexOf("inux")!=-1);
  716.  
  717. this.osSCO=(this.agent.indexOf("sco")!=-1)||(this.agent.indexOf("unix_sv")!=
  718. -1);
  719.   this.osUnixWare=(this.agent.indexOf("unix_system_v")!=-1);
  720.   this.osMPRAS=(this.agent.indexOf("ncr")!=-1);
  721.   this.osReliant=(this.agent.indexOf("reliantunix")!=-1);
  722.  
  723. this.osDEC=((this.agent.indexOf("dec")!=-1)||(this.agent.indexOf("osf1")!=-1
  724. )||(this.agent.indexOf("dec_alpha")!=-1)||(this.agent.indexOf("alphaserver")
  725. !=-1)||(this.agent.indexOf("ultrix")!=-1)||(this.agent.indexOf("alphastation
  726. ")!=-1));
  727.   this.osSinix=(this.agent.indexOf("sinix")!=-1);
  728.   this.osBSD=(this.agent.indexOf("bsd")!=-1);
  729.   this.osFreeBSD=(this.agent.indexOf("freebsd")!=-1);
  730.   this.osOpenBSD=(this.agent.indexOf("openbsd")!=-1);
  731.   this.osNetBSD=(this.agent.indexOf("netbsd")!=-1);
  732.   this.osBSDi=(this.agent.indexOf("bsdi")!=-1);
  733.  
  734. this.osUnix=((this.agent.indexOf("x11")!=-1)||this.osSun||this.osIrix||this.
  735. osHPUx||this.osSCO||this.osUnixWare||this.osMPRAS||this.osReliant||this.osDE
  736. C||this.osSinix||this.osAIX||this.osLinux||this.osBSD||this.osFreeBSD);
  737.  
  738. this.osVMS=((this.agent.indexOf("vax")!=-1)||(this.agent.indexOf("openvms")!
  739. =-1));
  740.   this.hostName=null;
  741.   this.hostAddress=null;
  742.   this.hostName=this.getHostName();
  743.   this.hostAddress=this.getHostAddress();
  744.   this.checkScreen();
  745. }
  746.  
  747. function Browser_checkScreen(){
  748.   if (top.screen){
  749.  
  750. (screen.pixelDepth)?this.pixelDepth=screen.pixelDepth:this.pixelDepth=null;
  751.  
  752. (screen.colorDepth)?this.colorDepth=screen.colorDepth:this.colorDepth=null;
  753.     if(screen.width&&screen.height){
  754.       this.screenWidth=screen.width;
  755.       this.screenHeight=screen.height;
  756.        this.screenResolution=this.screenWidth+"x"+this.screenHeight;
  757.     }else{
  758.       this.screenWidth=null;
  759.       this.screenHeight=null;
  760.       this.screenResolution=null;
  761.     }
  762.     if(screen.availWidth&&screen.availHeight){
  763.       this.availWidth=screen.availWidth;
  764.       this.availHeight=screen.availHeight;
  765.       this.availResolution=this.availWidth+"x"+this.availHeight;
  766.     }else{
  767.       this.availWidth=null;
  768.       this.availHeight=null;
  769.       this.availResolution=null;
  770.     }
  771.  
  772. if(this.screenWidth&&this.screenHeight&&this.colorDepth)this.Resolution=this
  773. ..screenWidth+"x"+this.screenHeight+"x"+this.colorDepth;
  774.     else this.Resolution = null;
  775.   }else{
  776.     this.pixelDepth=null;
  777.     this.colorDepth=null;
  778.     this.availWidth=null;
  779.     this.availHeight=null;
  780.     this.availResolution=null;
  781.     this.screenWidth=null;
  782.     this.screenHeight=null;
  783.     this.screenResolution=null;
  784.     this.Resolution=null;
  785.   }
  786.   if(window.innerWidth)this.innerWidth=window.innerWidth;
  787.   else{
  788.     if(document.body){
  789.       if(document.body.clientWidth)
  790. this.innerWidth=document.body.clientWidth;
  791.     }else this.innerWidth=null;
  792.   }
  793.   if(window.innerHeight)this.innerHeight=window.innerHeight;
  794.   else{
  795.     if(document.body){
  796.  
  797. if(document.body.clientHeight)this.innerHeight=document.body.clientHeight;
  798.     } else this.innerHeight=null;
  799.   }
  800.  
  801. (this.innerWidth&&this.innerHeight)?this.innerResolution=this.innerWidth+"x"
  802. +this.innerHeight:this.innerResolution=null;
  803.  
  804. (window.outerWidth)?this.outerWidth=window.outerWidth:this.outerWidth=null;
  805.  
  806. (window.outerHeight)?this.outerHeight=window.outerHeight:this.outerHeight=nu
  807. ll;
  808.   (this.outerWidth &&
  809. this.outerHeight)?this.outerResolution=this.outerWidth+"x"+this.outerHeight:
  810. this.outerResolution=null;
  811.  
  812. (window.offscreenBuffering)?this.offscreenBuffering=window.offscreenBufferin
  813. g:this.offscreenBuffering=null;
  814.   if(window.frameRate)this.frameRate=window.frameRate;
  815.   else this.frameRate=null;
  816. }
  817. function Browser_getCookieVal(offset){
  818.   var endstr=document.cookie.indexOf(";",offset);
  819.   if(endstr==-1)endstr=document.cookie.length;
  820.   return unescape(document.cookie.substring(offset,endstr));
  821. }
  822. function Browser_fixCookieDate(date){
  823.   var base=new Date(0);
  824.   var skew=base.getTime();
  825.   if(skew>0)date.setTime(date.getTime()-skew);
  826. }
  827. function Browser_getCookie(name){
  828.   var arg=name+"=";
  829.   var alen=arg.length;
  830.   var clen=document.cookie.length;
  831.   var i=0;
  832.   while(i<clen){
  833.     var j=i+alen;
  834.     if(document.cookie.substring(i,j)==arg)return this.getCookieVal(j);
  835.     i=document.cookie.indexOf(" ",i)+1;
  836.     if(i==0)break;
  837.   }
  838.   return null;
  839. }
  840. function Browser_setCookie(name,value,expires,path,domain,secure){
  841.   document.cookie=name+"="+escape(value)+((expires)?";
  842. expires="+expires.toGMTString():"")+((path)?"; path="+path:"")+((domain)?";
  843. domain="+domain:"")+((secure)?"; secure":"");
  844. }
  845. function Browser_deleteCookie(name,path,domain){
  846.   if(this.getCookie(name))document.cookie=name+"="+((path)?";
  847. path="+path:"")+((domain)?"; domain="+domain:"")+"; expires=Thu, 01-Jan-70
  848. 00:00:01 GMT";
  849. }
  850. function Browser_getHostName(){
  851.   if(navigator.appName.lastIndexOf('Netscape')!=-1)
  852.     if(navigator.javaEnabled()==1){
  853.       window.onerror=null;
  854.       hostAddress=java.net.InetAddress.getLocalHost();
  855.       return(hostAddress.getHostName());
  856.     }
  857.   return null;
  858. }
  859.  
  860.  
  861. IV. HTML tags, FORMs, FRAMEs
  862.  
  863. 1.┼±≥ⁿ ⌠εp∞α Γ Ωε≥εpεΘ ΣΓα ∞σφ■ Γ√ßεpα - ∩σpΓεσ πp≤∩∩α ≥εΓαpεΓ, Γ≥εpεσ -
  864. ±∩Φ±εΩ ≥εΓαpεΓ
  865. ┬ε∩pε± ΩαΩ ±Σσδα≥ⁿ ≈≥ε-ß√ Γε Γ≥εpε∞ ∞σφ■ Γ√⌡εΣΦδΦ ≥εδⁿΩε ≥εΓαp√ ΩεφΩpσ≥φεΘ
  866. πp≤∩∩√ ≥εΓαpεΓ ?
  867.  
  868. >>From: "Michael A. Kangin" <mak@complife.net>
  869.  
  870. ╧≡ΦΓσΣ≤ ±ε±≥≡ ∩αφφφ≤■ ∩≡επ≡α∞Ω≤. ╨ατßσ≡σ°ⁿ± ?
  871.  
  872. -----------------------
  873. <html>
  874.  
  875. <script>
  876. var tovar = new Array(4)
  877.  
  878. tovar[1]= new Array(
  879. "├≡εß√",
  880. "┬σφΩΦ",
  881. "╩α≥α⌠αδΩΦ",
  882. "╬≥∩σΓαφΦ ",
  883. "╧α∞ ≥φΦΩΦ",
  884. "╩≡σ±≥√"
  885. )
  886.  
  887. tovar[2]=new Array(
  888. "╩ε∞∩ⁿ■≥σ≡√ ßεδⁿ°Φσ",
  889. "╩ε∞∩ⁿ■≥σ≡√ ∞αδσφⁿΩΦσ",
  890. "┬Φφ≥≈σ±≥σ≡√",
  891. "╩α≡Ω≤δ ≥ε≡√"
  892. )
  893.  
  894. tovar[3]=new Array(
  895. "╬Ωφα",
  896. "─Γσ≡Φ",
  897. "╤δεΓα",
  898. "╥α≡αΩαφ√",
  899. "╞≤ΩΦ",
  900. "╩δε∩√"
  901. )
  902.  
  903. tovar[4]=new Array(
  904. "╪α∞∩≤φⁿ",
  905. "╩≡σ∞",
  906. "╠ατⁿ"
  907. )
  908.  
  909. function update_s2()
  910. {
  911. n=document.f1.s1.selectedIndex + 1;
  912. document.f1.s2.length=tovar[n].length;
  913. for(i=0; i<tovar[n].length; i++) document.f1.s2[i].text = tovar[n][i];
  914. }
  915. </script>
  916.  
  917. <body>
  918.  
  919. <form name="f1">
  920.  
  921. <table border=0 width=100%>
  922. <tr valign=top><td>
  923. ╘Φ≡∞α<br>
  924.  
  925.  <select name="s1" size=4 onChange="update_s2()">
  926.   <option selected>┴σφτσφ≈≤Ω Φ ╩
  927.   <option>IBM
  928.   <option>Microsoft
  929.   <option>╧╨εΩ≥σ≡ Φ πσ∞ßδ
  930.  </select>
  931.  
  932. </td>
  933. <td>
  934. ╥εΓα≡:<br>
  935.  
  936.  <select name="s2" size=7 width=200>
  937.   <script>
  938.   for(i=0; i<tovar[1].length; i++) document.writeln('<option>'+tovar[1][i]);
  939.   </script>
  940.  </select>
  941.  
  942. </td></tr>
  943. </table>
  944. </form>
  945.  
  946. </body>
  947. </html>
  948. -------------------------------------------------
  949.  
  950. ╨αßε≥ασ≥ ΩαΩ ∞ΦφΦ∞≤∞ Γ MIE5 Φ Hσ≥±Ωα∩σ 4.08. ╒ε≥  ╠╚┼ ΩαΩ-≥ε ±≥≡αφφε
  951. ≡σαπΦ≡≤σ≥
  952. φα
  953. Φτ∞σφσφΦσ τφα≈σφΦΘ, ∩σ≡σΣσ≡πΦΓασ≥ Γ±σ ∩εδσ Γ√ßε≡α. ╠εµσ≥, ∩ε⌠ΦΩ±Φ≥ⁿ Φ ∞εµφε,
  954. φσ
  955. ≡ατßΦ≡αδ± .
  956.  
  957. 2. ∞εµφε δΦ Γ√τ√Γα≥ⁿ  Γα±ΩpΦ∩≥ ∩ε∞σ∙σφφ√Θ Γ εΣΦφ ⌠αΘδΦΩ (⌠pσΘ∞) Φτ Σp≤πΦ⌡
  958. ⌠pσΘ∞εΓ... σ±δΦ ∞εµφε, ≥ε ΩαΩ?
  959.  
  960. >> From : Artem Babadzhanyants        2:5030/922      Sat 13 Nov 99 18:23
  961. ╥σΩ±≥ ±Ω≡Φ∩≥α ∩Φ°σ°ⁿ Γ ε≥Σσδⁿφε∞ ⌠αΘδσ, α φα ±≥≡αφΦ≈Ωσ ∩Φ°σ°ⁿ:
  962.  
  963. <HTML>
  964. <SCRIPT LANGUAGE="JavaScript" SRC="b5bbs.js">
  965. </SCRIPT>
  966. <SCRIPT LANGUAGE="JavaScript" SRC="link.js">
  967. </SCRIPT>
  968. </HTML>
  969.  
  970. ≥.σ ∞εΦ ±Ω≡Φ∩≥√ φα⌡εΣ ≥±  Γ ⌠αΘδα⌡ b5bbs.js Φ link.js
  971.  
  972.  
  973. 3. ┼±≥ⁿ 2 ⌠pσΘ∞α ßαφφσp Φ ε±φεΓφεΘ, φαΣε τΣσδα≥ⁿ ≥αΩ ≈≥εß√ ∩pΦ ΩδΦΩσ φα
  974. Ωφε∩Ωy(pΦ±yφεΩ,±±√δΩy)Γ ΓpσΘ∞σ ± ßαφσpε∞ ⌠pσΘ∞ ταΩp√δ±  Φ ε±≥αδ± 
  975. ≥εδⁿΩε ε±φεΓφεΘ. ╧ε∞επΦ≥σ ∩δΦτ..
  976.  
  977. >> From : Alexander Hritonenkov               2:5030/978.33   Sat 04 Mar 00
  978. 15:05
  979.  
  980.  
  981. <A HREF="..." TARGET="_parent">...</A>
  982. ΦδΦ
  983. <A HREF="..." TARGET="_top">...</A>
  984.  
  985. 4. ┬ε≥ ≥αΩ ∩εδ≤≈α■≥±  ╫└╤█
  986. >> From : Anton Agapov                        2:5030/854.22   Mon 27 Mar 00
  987. 15:48
  988.  
  989. <FORM NAME="clock">
  990.  <INPUT NAME="face" TYPE="TEXT" VALUE="hh:mm:ss" SIZE=6>
  991.  </FORM>
  992.  <SCRIPT LANGUAGE="JavaScript">
  993.  <!--
  994.  updateClock();
  995.  
  996.  function updateClock() {
  997.      var time = new Date();
  998.      var hours = time.getHours();
  999.      var minutes = time.getMinutes();
  1000.      var seconds = time.getSeconds();
  1001.      document.clock.face.value =
  1002.                                  ((hours < 10) ? '0' + hours : hours) +
  1003.                            ':' + ((minutes < 10) ? '0' + minutes : minutes)
  1004. +
  1005.                            ':' + ((seconds < 10) ? '0' + seconds : seconds);
  1006.      setTimeout("updateClock()",1000);
  1007.  }
  1008. //-->
  1009. </SCRIPT>
  1010. <p>
  1011.  
  1012. 5.╩αΩ ±Σσδα≥ⁿ ±αßµ, ≈≥εß√ ∩ε±δσ φαµα≥Φ  φα Ωφε∩Ω≤ "Submit" ∩εδ  ⌠ε≡∞√
  1013. ∩≡εΓσ≡ δΦ±ⁿ  Γα-±Ω≡Φ∩≥ε∞, α ∩ε≥ε∞ ≥εδⁿΩε, σ±δΦ Γ±σ ⌠ε≡∞√ τα∩εδφσφ√ ≥αΩ
  1014. ≥αΩ φαΣε, Σαφφ√σ ∩σ≡σΣαΓαδΦ±ⁿ ±σ≡Γσ≡≤ ?
  1015.  
  1016. >> From : Vitaly Vasilchuk                    2:5020/400      Fri 07 Apr 00
  1017. 15:02
  1018. ┬ html'σ, Γ ⌠ε≡∞σ, Ωφε∩Ωα Submit, Σεδµφα ß√≥ⁿ ε∩Φ±αφα ±δσΣ≤■∙Φ∞ εß≡ατε∞
  1019. ---------------------------------
  1020. <input type="button" value="╬≥∩≡αΓΦ≥ⁿ"
  1021.  onclick="ConfirmBox(this.form, '┬√ ΣσΘ±≥ΓΦ≥σδⁿφε ⌡ε≥Φ≥σ ε≥∩≡αΓΦ≥ⁿ
  1022. τα∩≡ε±?')">
  1023. ---------------------------------
  1024.  
  1025. α Γε≥ ±Ω≡Φ∩≥
  1026. ---------------------------------
  1027. function ConfirmBox(f, message) {
  1028.   // ∩≡εΓσ≡Ωα ∩εδ  Sum
  1029.   if (f.Sum.value=="0") {
  1030.     // Γ√ΓεΣΦ∞ ±εεß∙σφΦσ εß ε°ΦßΩσ
  1031.     alert('Hσεß⌡εΣΦ∞ε Γ√ß≡α≥ⁿ εΣφ≤ Φτ ταΣα≈.');
  1032.     // ΓετΓ≡α∙ασ∞ ⌠εΩ≤± φα ⌠ε≡∞σ Γ ²≥ε ∞σ±≥ε
  1033.     f.cb_MU.focus();
  1034.     return false;
  1035.   }
  1036.  
  1037.   // Γ√ΓεΣ τα∩≡ε±α
  1038.   if (confirm(message)) {
  1039.     // σ±δΦ ∩εδⁿτεΓα≥ⁿ ≥ε∩≈σ≥ "Yes" - ε≥∩≡αΓδ σ∞
  1040.     f.submit();      <-- ±α∞ ≥≡■Ω
  1041.     return true;
  1042.   }
  1043.   else
  1044.     return false;
  1045. }
  1046.  
  1047.  
  1048. 6.╩≥ε-φΦß≤Σⁿ τφασ≥, ΩαΩ ∩≡εΦπ≡α≥ⁿ wav ⌠αΘδ Γ Internet Explorere?
  1049. (≥≡σß≤σ≥±  τΓ≤Ω ∩≡Φ φαΓσΣσφΦΦ ∞√°Φ φα εß·σΩ≥)
  1050.  
  1051. >> From : Raidillon Eaurouge       2:5020/400      Sun 01 Oct 00 02:00
  1052.  
  1053. ╧≡εΓσ≡Φδ Γ win98, IE5.0 (5.00.2614.3500)...
  1054. ╨αßε≥ασ≥!
  1055.  
  1056. <sample runsInIE5_0="yes">
  1057. <HTML>
  1058. <BODY>
  1059. <SCRIPT LANGUAGE="JavaScript">
  1060. <!--
  1061. var strOver = "1.wav";
  1062. var strClick = "2.wav";
  1063. var a = new Array("never", "say", "die");
  1064.  
  1065. for (var i = 0; i < a.length; i++)
  1066.  document.writeln('<p><a href="#"'
  1067.   + ' onmouseover="soundIt(false)"'
  1068.   + ' onclick="soundIt(true)">'
  1069.   + a[i] + '</a></p>');
  1070.  
  1071. function soundIt(cause)
  1072. {
  1073.  sounder.src = (cause ? strClick : strOver);
  1074. }
  1075. //-->
  1076. </SCRIPT>
  1077. <bgsound id="sounder"/>
  1078. </BODY>
  1079. </HTML>
  1080. </sample>
  1081.  
  1082. >>From:  Andrew Rousev
  1083.  
  1084. ╚τ ClientGuide JS1.3:
  1085.  
  1086.    *JavaScript Methods for Controlling LiveAudio*
  1087.  
  1088. LiveAudio provides the following major JavaScript controlling methods. For
  1089. these methods to be available to JavaScript (and the web page), you must
  1090. embed
  1091. a LiveAudio console (any console will do, it can even be hidden) somewhere
  1092. on
  1093. your page.
  1094.  
  1095. play({loop[TRUE, FALSE or an INT]}, '{url_to_sound}')
  1096. pause()
  1097. stop()
  1098. StopAll()
  1099. start_time({number of seconds})
  1100. end_time({number of seconds})
  1101. setvol({percentage number - without "%" sign})
  1102. fade_to({volume percent to fade to, without the "%"})
  1103. fade_from_to({volume % start fade}, {volume % end fade})
  1104. start_at_beginning()
  1105. stop_at_end()
  1106.  
  1107. The following JavaScript state indication methods do not control the
  1108. LiveAudio
  1109. plug-in, but they give you information about the current state of the
  1110. plug-in:
  1111.  
  1112. IsReady
  1113. IsPlaying
  1114. IsPaused
  1115. GetVolume
  1116.  
  1117. ---------
  1118. Using the LiveAudio LiveConnect Methods
  1119. One example of using JavaScript to control a LiveAudio plug-in is to have
  1120. JavaScript play a sound. In the following example, all of the HTML is needed
  1121. to
  1122. make the plug-in play a sound.
  1123.  
  1124. <HTML><BODY>
  1125. <EMBED SRC="sound1.wav"   HIDDEN=TRUE>
  1126. <A HREF="javascript:document.embeds[0].play(false)">Play the sound now!</A>
  1127. </BODY></HTML>
  1128.  
  1129.  
  1130.  
  1131. function Browser_getHostAddress(){
  1132.   if (navigator.appName.lastIndexOf('Netscape')!=-1)
  1133.     if(navigator.javaEnabled()==1){
  1134.       window.onerror=null;
  1135.       hostAddress=java.net.InetAddress.getLocalHost();
  1136.       return(hostAddress.getHostAddress());
  1137.     }
  1138.   return null;
  1139. }
  1140. var browser=new Browser();
  1141.  
  1142.  
  1143. V. Dynamic HTML, LAYERs, DIVs, DOM, CSS
  1144.  
  1145. 1. ╒ε≥σδε±ⁿ ß√ φσ ταßΦΓα≥ⁿ ≥²πΦ JavaScript-εΓ±ΩΦ∞Φ onMouseOver="..." Φ ≥.∩.,
  1146. α ∩≡ε±≥ε ÷σ∩δ ≥ⁿ CSS Ω  ΣεΩ≤∞σφ≥≤ Φ Γ±σ.
  1147.  
  1148. From "Raidillon Eaurouge" <nero@iptelecom.net.ua> wrote in message
  1149.  
  1150.  <style>
  1151.  .umm {
  1152.   behavior: url('umm.htc')
  1153.  }
  1154.  </style>
  1155.  
  1156.  <component>
  1157.  <implements>
  1158.   <attach event="onmouseover" onevent="over()" />
  1159.   <attach event="onmouseout" onevent="out()" />
  1160.   <attach event="onclick" onevent="clika()" />
  1161.  </implements>
  1162.  </component>
  1163.  
  1164. > └ σ±δΦ ≤µσ ∩≡ε∩Φ±αφα Ω≤≈α ≈α±≥φ√⌡ ±δ≤≈ασΓ onmouseover() Φ onclick(), φε
  1165. ⌡ε≈σ≥± 
  1166. > Ωε Γ±σ∞ ±≡ατ≤ ΣεßαΓΦ≥ⁿ Φ onfocus(), ß≤Σσ≥ δΦ ≡αßε≥α≥ⁿ ≥αΩα  Ωεφ±≥≡≤Ω÷Φ :
  1167. > <component>
  1168. > <implements>
  1169. > <attach event="onfocus" onevent="this.blur()" />
  1170. > </implements>
  1171.  
  1172. ┴≤Σσ≥ ≡αßε≥α≥ⁿ, φε Γ Ωε∞∩εφσφ≥α⌡ φ≤µφε Φ±∩εδⁿτεΓα≥ⁿ φσ "this",
  1173. α "element" Σδ  εß≡α∙σφΦ  Ω ±ΓεΦ∞ ±ΓεΘ±≥Γα∞ Φ ∞σ≥εΣα∞ -- element.blur().
  1174.  
  1175.  
  1176. ∩ε≈Φ≥α≥ⁿ ∞εµφε Γ MSDN - DHTML Behaviors in Internet Explorer 5
  1177.